package com.awifi.com.thread.communication;

/**
 * @description: ToDo
 * @author: marin
 * @time: 2020/6/29 16:18
 */
public class ThreadCommunication {
    public static void main(String[] args) {

        Cake cake = new Cake();
        cake.setFlag(true);

        Consumer consumer = new Consumer("consumer1",cake);
        Producer producer = new Producer("producer1",cake);

        consumer.start();
        producer.start();
    }
}
